home *** CD-ROM | disk | FTP | other *** search
/ Columbia Kermit / kermit.zip / newsgroups / misc.20031118-20041115 / 000417_robertls@nortelnetworks.com_Tue Oct 19 17:27:41 2004.msg < prev    next >
Internet Message Format  |  2020-01-01  |  3KB

  1. Path: newsmaster.cc.columbia.edu!newsfeed.nyu.edu!newsfeed.telusplanet.net!newsfeed.telus.net!snoopy.risq.qc.ca!torn!utnut!qcarhaaa.nortelnetworks.com!bcarh189.ca.nortel.com!zcars0v6!not-for-mail
  2. From: "Robert Simmons" <robertls@nortelnetworks.com>
  3. Newsgroups: comp.protocols.kermit.misc
  4. Subject: Re: Kermit Script Output Out of Order
  5. Date: Tue, 19 Oct 2004 15:27:46 -0500
  6. Organization: Nortel
  7. Lines: 48
  8. Message-ID: <cl3tc5$5n0$1@zcars0v6.ca.nortel.com>
  9. References: <cl29ql$dm7$1@zcars0v6.ca.nortel.com> <slrncnan01.3s1.fdc@sesame.cc.columbia.edu>
  10. NNTP-Posting-Host: robertls-1.us.nortel.com
  11. X-Trace: zcars0v6.ca.nortel.com 1098217669 5856 47.102.125.229 (19 Oct 2004 20:27:49 GMT)
  12. X-Complaints-To: hawkinsj@nortelnetworks.com
  13. NNTP-Posting-Date: Tue, 19 Oct 2004 20:27:49 +0000 (UTC)
  14. X-Priority: 3
  15. X-MSMail-Priority: Normal
  16. X-Newsreader: Microsoft Outlook Express 6.00.2800.1158
  17. X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165
  18. Xref: newsmaster.cc.columbia.edu comp.protocols.kermit.misc:15200
  19.  
  20.  
  21. Okay... I'll look into the buffered vs. unbuffered mode.  But what about the
  22. output when it is redirected to a file.  The output from kermit is out of
  23. order there as well.
  24.  
  25. Robert
  26.  
  27.  
  28. "Frank da Cruz" <fdc@columbia.edu> wrote in message
  29. news:slrncnan01.3s1.fdc@sesame.cc.columbia.edu...
  30. > On 2004-10-19, Robert Simmons <robertls@nortelnetworks.com> wrote:
  31. > : Hopefully this group is still monitored...
  32. > :
  33. > Of course.
  34. >
  35. > : I have been developing a kermit script.  I have found that when a run
  36. the
  37. > : script normally from a linux prompt that the output is mostly in order.
  38. But
  39. > : if I fork a process and run the script from a C++ program the output is
  40. in
  41. > : realtime for the AT responces but the script echo lines and the help
  42. text
  43. > : output is not dumped until the process is killed or dies.
  44. > :
  45. > : I notices the same order of output with the stdout redirected and
  46. captured
  47. > : to a file at the linux command prompt.
  48. > :
  49. > : Anyone know why? And how to get the output os the echo statements to be
  50. dump
  51. > : before the script dies or is killed?
  52. > :
  53. > C-Kermit was not really intended to be controlled by another process.
  54. > When you use Kermit itself as your scripting tool, which is adequate for
  55. > most purposes:
  56. >
  57. >   http://www.columbia.edu/kermit/ckscripts.html
  58. >
  59. > you don't get the jumbled output.
  60. >
  61. > For historical (and to some extent practical) reasons, there is a mixture
  62. > of buffered and unbuffered writes to stdout.  If your process is reading
  63. > C-Kermit's stdout, maybe it needs to read it in unbuffered mode?
  64. >
  65. > - Frank
  66.  
  67.